<?php $__env->startSection('content'); ?>
    <div class="cart-index" id="more" <?php if(!$orders->isEmpty()): ?> style="display: none;" <?php endif; ?>>
        <div style="height:1rem;"></div>

        <div class="cart-index-wrap">
            <div class="empt">
                <div class="b3">
                    <a href="/product/category" class="ui-button ui-button-disable">
                        <span>全部商品</span>
                    </a>
                    <a href="/" class="ui-button">
                        <span>精选商品</span>
                    </a>
                </div>
            </div>
        </div>
    </div>

    <div class="page-my-order" data-log="我的订单" <?php if($orders->isEmpty()): ?> style="display: none;" <?php endif; ?>>

        <div class="order_list">

            <?php foreach($orders as $order): ?>
                <div class="ol-item" onclick="location.href='/order/<?php echo e($order->id); ?>'">
                    <div>
                        <div class="oi1">
                            <div class="oi11">
                                <div class="oi111"><p>
                                        <strong>订单日期：</strong><span><?php echo e($order->created_at->format('Y/m/d H:i')); ?></span>
                                    </p></div>
                                <div class="oi112"><p><strong>订单编号：</strong><span><?php echo e($order->id); ?></span></p></div>
                            </div>
                            <div class="oi12"><p><?php echo e($order_status["$order->status"]); ?></p></div>
                        </div>
                        <div class="oi2">
                            <ul>
                                <?php foreach($order->order_products as $order_product): ?>
                                    <li>
                                        <div class="oi21">
                                            <div class="img"><img src="<?php echo e($order_product->product->thumb); ?>">
                                            </div>
                                        </div>
                                        <div class="oi22"><p><?php echo e($order_product->product->name); ?></p></div>
                                    </li>
                                <?php endforeach; ?>
                            </ul>
                        </div>
                        <div class="oi3">
                            <p>
                                <span>共<?php echo e($order->order_products[0]->num); ?>件商品</span>
                                <span>总金额：</span><strong><?php echo e(doubleval($order->total_price)); ?>元</strong>
                            </p>
                        </div>

                        <?php if($order->status=='1'): ?>
                            <div class="oi4">
                                <a href="/order/pay/<?php echo e($order->id); ?>" class="org">立即付款</a>
                                <a href="/order/<?php echo e($order->id); ?>" data-method="delete" data-token="<?php echo e(csrf_token()); ?>">取消订单</a>
                            </div>
                        <?php endif; ?>
                    </div>
                </div>
            <?php endforeach; ?>
        </div>
    </div>
    <?php echo $__env->make('home.layouts._footer', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>

<?php $__env->stopSection(); ?>
<?php $__env->startSection('js'); ?>
<script src="/assets/mi/js/jquery.min.js"></script>
<?php $__env->stopSection(); ?>


<?php echo $__env->make('home.layouts.application', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>